package com.jrx.anytxn.param.controller.login;
import jrx.auth.filter.config.FilterSettings;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import javax.servlet.http.HttpServletResponse;
import java.io.IOException;

/**
 * 登陆成功后重定向到前端
 * @author Qingyao Xing
 * @date 2019/10/12
 */
@RestController
public class LoginRedirectController {
    @Autowired
    private FilterSettings filterSettings;
    @GetMapping(value = {"/param/login/redict"})
    public String redict(HttpServletResponse response) throws IOException {
        response.sendRedirect(filterSettings.getIndexUrl());
        return null;
    }
}
